package com.juc.forkJoinPool.forkJoinPool7;

import java.util.concurrent.ForkJoinPool;
import java.util.concurrent.ForkJoinTask;

public class Run1 {
     // public <T> ForkJoinTask<T> submit(Runnable task, T result)
	public static void main(String[] args) throws InterruptedException {
		Userinfo userinfo = new Userinfo();
		MyRunnable runnable = new MyRunnable(userinfo);
		ForkJoinPool pool = new ForkJoinPool();
		pool.submit(runnable,userinfo);
		System.out.println();
		//取不到值
		System.out.println("userinfo  username " + userinfo.getUsername());
		Thread.sleep(2000);
	}
}
